import request from "@/utils/request";

// 学科管理模块Api

// 标签信息子模块，标签信息子模块，标签信息子模块

// 标签数据列表
export const GetTagList = params => {
  return request({
    url: '/subject/tag',
    params
  })
}

// 标签增加新增
export const PostTsgApi = params => {
  return request({
    url: '/subject/tag',
    method: 'POST',
    params
  })
}

// 标签删除
export const DeleteTagApi = id => {
  return request({
    url: `/subject/tag/${id}`,
    method: 'DELETE',
    params: { id }
  })
}

// 获取单个标签
export const ErrnoeTagApi = id => {
  return request({
    url: `/subject/directory/${id}`,
  })
}

// 标签修改
export const PutTagApi = data => {
  return request({
    url: `/subject/tag/${data.id}`,
    method: 'PUT',
    data
  })
}
// 归属学科查询
export const queryTagApi = data => { //搜索条件中归属学科下拉数据显示
  return request({
    url: `/subject/subject`,
    data
  })
}


// 标签状态修改
export const StateTagyApi = data => {
  return request({
    url: `/subject/tag/${data.id}/state`,
    method: 'PUT',
    data
  })
}


// 标签表单回显
export const StateTagyListApi = data => {
  return request({
    url: `/subject/tag/${data.id}`,
    data
  })
}
